home *** CD-ROM | disk | FTP | other *** search
/ Aminet 2 / Aminet AMIGA CDROM (1994)(Walnut Creek)[Feb 1994][W.O. 44790-1].iso / Aminet / dev / lang / small304.lha / Smalltalk / src / makefile < prev    next >
Makefile  |  1993-05-08  |  4KB  |  121 lines

  1. CFLAGS = -O
  2.  
  3. # define groups of files, to make later commands easier
  4. INTERPc = memory.c names.c news.c interp.c
  5. INTERPo = memory.o names.o news.o interp.o
  6. PRIMITIVEc = primitive.c filein.c lex.c parser.c unixio.c
  7. PRIMITIVEo = primitive.o filein.o lex.o parser.o unixio.o
  8. basicST = basic.st mag.st collect.st 
  9. unixST = file.st mult.st 
  10. testST = test.st queen.st
  11. CFILES = *.h $(INTERPc) $(PRIMITIVEc) st.c initial.c tty.c winprim.c
  12. OFILES = $(INTERPo) $(PRIMITIVEo) 
  13. STFILES = $(basicST) $(unixST) $(testST) tty.st graphics.st stdwin.st
  14. FILES = README Makefile vms.com $(CFILES) $(STFILES) *.ms
  15. # the following are used only by turboc on the ibm pc
  16. TURBOc=memory names news interp primitive filein lex parser unixio tty
  17. TINCLUDE=c:\turboc\include
  18. TLIB=c:\turboc\lib
  19. INTERFACE=
  20. MANXc=memory.c names.c news.c interp.c primitive.c filein.c lex.c parser.c \
  21.  unixio.c tty.c st.c initial.c
  22. MANXo=memory.o names.o news.o interp.o primitive.o filein.o lex.o parser.o \
  23.  unixio.o tty.o
  24.  
  25. # the following is for those poor souls who say ``make'' without looking
  26. help:
  27.     @echo "select one of the following to make"
  28.     @echo "bsdtty: Berkeley 4.2/4.3 with teletype interface "
  29.     @echo "sysvtty: System V with teletype interface "
  30.     @echo "bsdx11: Berkeley 4.2/4.3 with stdwin interface on top of X11"
  31.     @echo "ibmturboc: IBM PC with Turbo C compiler (see install.ms)"
  32.  
  33. winfiles: $(OFILES) winprim.o initial.o st.o
  34.  
  35. # initial - the initial object maker
  36. initial: $(INTERPo) $(PRIMITIVEo) initial.o $(INTERFACE)
  37.     cc -o initial $(CFLAGS) $(INTERPo) $(PRIMITIVEo) initial.o $(INTERFACE) -lm $(LIBS)
  38.  
  39. # st - the actual bytecode interpreter
  40. st: $(INTERPo) $(PRIMITIVEo) st.o $(INTERFACE)
  41.     cc -o st $(CFLAGS) $(INTERPo) $(PRIMITIVEo) st.o $(INTERFACE) -lm $(LIBS)
  42.  
  43. # bsdtty - berkeley 4.2/4.3 with tty style interface
  44. bsdtty:
  45.     make "CFLAGS=$(CFLAGS) -DB42" "LIBS=" "INTERFACE= tty.o" initial st
  46.     initial $(basicST) $(unixST) tty.st
  47.  
  48. bsdtty.lint:
  49.     lint -DB42 $(INTERPc) $(PRIMITIVEc) tty.c initial.c -lm
  50.     lint -DB42 $(INTERPc) $(PRIMITIVEc) tty.c st.c -lm
  51.  
  52. # sysvtty - system V with tty style interface
  53. sysvtty:
  54.     make "CFLAGS=$(CFLAGS) -DSYSV" "LIBS=" "INTERFACE= tty.o" initial st
  55.     initial $(basicST) $(unixST) tty.st
  56.  
  57. sysvtty.lint:
  58.     lint -DSYSV $(INTERPc) $(PRIMITIVEc) tty.c initial.c -lm
  59.     lint -DSYSV $(INTERPc) $(PRIMITIVEc) tty.c st.c -lm
  60.  
  61. # bsdterm - berkekey 4.2/4.3 with stdwin interface on top of termcap
  62. # requires Guido van Rossum's standard window package
  63. # (currently doesn't work)
  64. bsdterm: stdw.o
  65.     make "CFLAGS=$(CFLAGS) -DB42 -DSTDWIN" "LIBS= -ltermcap" "INTERFACE= winprim.o stdw.o" initial st
  66.     initial $(basicST) $(unixST) graphics.st stdwin.st
  67.  
  68. # bsdx11 - berkekey 4.2/4.3 with stdwin interface on top of x11
  69. # requires Guido van Rossum's standard window package
  70. bsdx11: stdw.o
  71.     make "CFLAGS=$(CFLAGS) -DB42 -DSTDWIN" "LIBS= -lX" "INTERFACE= winprim.o stdw.o" initial st
  72.     initial $(basicST) $(unixST) graphics.st stdwin.st
  73.  
  74. bsdx11.lint:
  75.     lint -DB42 -DSTDWIN $(INTERPc) $(PRIMITIVEc) winprim.c initial.c -lm -lX
  76.     lint -DB42 -DSTDWIN $(INTERPc) $(PRIMITIVEc) winprim.c st.c -lm -lX
  77.  
  78. # amigamanx - Amiga with Manx Aztec C 5.2a compiler
  79. # see installation notes for editing that must be performed first
  80. amigamanx: $(MANXo)
  81.         ln  -o st st.o $(MANXo) -lm -lc
  82.     ln  -o initial initial.o $(MANXo) -lm -lc
  83.     initial basic.st mag.st collect.st file.st mult.st tty.st
  84.         mv systemImage /
  85.         mv st /
  86.  
  87. $(MANXo): $(MANXc)
  88.     cc  $*.c
  89. st.o : st.c env.h memory.h names.h 
  90.         cc st
  91. initial.o : initial.c env.h memory.h names.h 
  92.         cc initial
  93.  
  94. # stdw.o - guidos van rossum's standard window package
  95. stdw.o:
  96.     @echo to create stdw.o see installation instructions
  97.  
  98. # all the dependencies on .h files
  99. filein.o : filein.c env.h memory.h names.h lex.h 
  100. initial.o : initial.c env.h memory.h names.h 
  101. interp.o : interp.c env.h memory.h names.h interp.h 
  102. lex.o : lex.c env.h memory.h lex.h 
  103. memory.o : memory.c env.h memory.h 
  104. names.o : names.c env.h memory.h names.h 
  105. news.o : news.c env.h memory.h names.h 
  106. parser.o : parser.c env.h memory.h names.h interp.h lex.h 
  107. primitive.o : primitive.c env.h memory.h names.h 
  108. st.o : st.c env.h memory.h names.h 
  109. tty.o : tty.c env.h memory.h 
  110. unixio.o : unixio.c env.h memory.h names.h 
  111. winprim.o : winprim.c stdwin.h stdevent.h stdtext.h env.h memory.h names.h 
  112.  
  113. # - pack - pack up the files for mailing
  114. pack: $(FILES)
  115.     packmail $(FILES)
  116.  
  117. # - tar - make a compressed tar file
  118. tar: $(FILES)
  119.     tar cvf small.v3.tar $(FILES)
  120.     compress small.v3.tar
  121.